/* =====================================================
   GLOBAL BASICS
===================================================== */
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  background: #ffffff;
  color: #000;
}

/* =====================================================
   HEADER / NAVIGATION
===================================================== */
header {
  font-family: 'Exo', sans-serif;
  background-color: #000;
  padding: 1rem 2rem;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  }

.header-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
}

.logo {
  font-weight: 700;
  color: #777;
}

nav {
  display: flex;
  gap: 1rem;
}

nav a {
  color: #f1f904;
  text-decoration: none;
  font-weight: 500;
}

nav a:hover {
  text-decoration: underline;
}

.title-header {
  text-align: center;
  margin-top: 1rem;
}

.title-header h2 {
  color: #fff;
  margin: 0;
  font-size: clamp(1.8rem, 6vw, 3rem);
}

.subtitle {
  text-align: center;
  color: #f1f904;
  margin-top: 0.4rem;
  font-size: 0.95rem;
}

/* =====================================================
   PAGE CONTAINER & GRID
===================================================== */
.container {
  display: flex;       /* nebeneinander */
  gap: 20px;           /* Abstand zwischen Cards */
  width: 90%;          /* Gesamtbreite */
  margin: 0 auto;      /* zentrieren */
}

.grid {
  display: grid;
  grid-template-columns: 3fr 7fr;
  gap: 14px;
  align-items: stretch;
}

@media (max-width: 900px) {
  .grid {
    grid-template-columns: 1fr;
  }
}

/* =====================================================
   CARD LAYOUT
===================================================== */
.card {
  background: #f9f9f9;
  border-radius: 16px;
  box-shadow: 0 8px 24px rgba(0,0,0,.15);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.card-header {
  padding: 10px 14px;
  font-weight: 700;
  border-bottom: 1px solid #ddd;
  background: #f0f0f0;
}

.card-content {
  padding: 12px;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 8px; /* kompakter */
}

/* =====================================================
   LEFT COLUMN – CONTROLS
===================================================== */
.reaction {
  font-size: 1.3em;
  text-align: center;
  background: #ffffff;
  padding: 8px;
  border-radius: 10px;
  box-shadow: 0 3px 10px rgba(0,0,0,.1);
}

.reaction input {
  width: 56px;
  text-align: center;
  font-size: 1em;
}

/* ===== SLIDER BOX (NEU) ===== */
.control-group {
  background: #ffffff;
  padding: 8px 10px;        /* flacher */
  border-radius: 10px;
  box-shadow: 0 3px 10px rgba(0,0,0,.1);
  display: grid;
  grid-template-columns: 1fr auto;
  grid-template-areas:
    "label label"
    "slider value";
  row-gap: 4px;
  column-gap: 10px;
  align-items: center;
}

.control-group label {
  grid-area: label;
  font-size: 0.8em;
  font-weight: 600;
  text-align: center;
}

.control-group input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 6px;
  border-radius: 6px;
  background: linear-gradient(90deg, #f1f904, #ffd900);
  outline: none;
  transition: all 0.2s ease;
}

/* TRACK (Chrome / Safari) */
.control-group input[type="range"]::-webkit-slider-runnable-track {
  height: 6px;
  border-radius: 6px;
  background: linear-gradient(90deg, #f1f904, #ffd900);
}

/* THUMB (Chrome / Safari) */
.control-group input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  height: 18px;
  width: 18px;
  border-radius: 50%;
  background: #000;
  border: 3px solid #f1f904;
  cursor: pointer;
  margin-top: -6px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.25);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

/* Hover Effekt */
.control-group input[type="range"]::-webkit-slider-thumb:hover {
  transform: scale(1.15);
  box-shadow: 0 4px 10px rgba(0,0,0,0.35);
}

/* Firefox Track */
.control-group input[type="range"]::-moz-range-track {
  height: 6px;
  border-radius: 6px;
  background: linear-gradient(90deg, #f1f904, #ffd900);
}

/* Firefox Thumb */
.control-group input[type="range"]::-moz-range-thumb {
  height: 18px;
  width: 18px;
  border-radius: 50%;
  background: #000;
  border: 3px solid #f1f904;
  cursor: pointer;
  box-shadow: 0 2px 6px rgba(0,0,0,0.25);
}

.control-group span {
  grid-area: value;
  min-width: 48px;
  text-align: right;
  font-weight: 600;
  font-size: 0.85em;
  color: #333;
}

.controls-card, .graph-card {
  background-color: #f5f5f5;
  border-radius: 10px;
  padding: 20px;
  box-shadow: 0 4px 8px rgba(0,0,0,0.1);
  box-sizing: border-box;
}

/* Checkbox-Gruppe kompakt */
.control-group input[type="checkbox"] {
  margin-right: 4px;
}

/* =====================================================
   RIGHT COLUMN – CHART
===================================================== */
.chart-wrapper {
  flex: 1;
}

canvas {
  width: 100% !important;
  height: 100% !important;
  background: #ffffff;
  border-radius: 12px;
}

/* =====================================================
   OPTIONAL HELPERS
===================================================== */
.center {
  text-align: center;
}

.small {
  font-size: 0.8em;
  color: #555;
}
/* =====================================================
   CONTROL GROUP – CHECKBOX ONLY (z.B. Sichtbarkeit)
===================================================== */
.control-group:has(input[type="checkbox"]) {
  display: block;
  padding: 10px;
}

.control-group:has(input[type="checkbox"]) label {
  display: block;
  text-align: left;
  font-size: 0.85em;
  font-weight: 600;
  margin-bottom: 6px;
}

.control-group:has(input[type="checkbox"]) input[type="checkbox"] {
  margin-right: 6px;
}
